<?php
class Myh_Mail extends Zend_Mail
{
	public function sendMail($subject, $body, $transports, $optionmail)
	{
		parent::__construct('utf-8');
		$config = array('auth'=>'login',
						'username'=>$transports['username'],
						'password'=>$transports['password']);
		$transport = new Zend_Mail_Transport_Smtp($transports['host'], $config);
		$this->setFrom($optionmail['fromemail'], $optionmail['fromname']);
		$this->addTo($optionmail['toemail'], $optionmail['toname']);
		$this->setSubject($subject);
		$this->setBodyHtml($body);
		$this->send($transport);
	}
}